1、电话号码的字母组合
思想：回溯
每个字母都有对应的字母，按照数字一条路走下去，然后依次回溯回来
class Solution {
public:
    string phone[10]={"","","abc","def","ghi","jkl","mno","pqrs","tuv","wxyz"};
    void dfs(vector<string>& solution,string& digits,string curSum,int index)
    {
        if(index==digits.size())
        {
            solution.push_back(curSum);
            return ;
        }
        string s=phone[digits[index]-'0'];//求出数字对应的字符串
        for(auto e:s)
        {
            dfs(solution,digits,curSum+e,index+1);
        }
    }
    vector<string> letterCombinations(string digits) {
        vector<string> solution;
        if(digits.empty())
            return solution;
        dfs(solution,digits,"",0);
        return solution;
    }
};